﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;

namespace WeiTap.RestClient
{
    /// <summary>
    /// 返回的Cookie值
    /// </summary>
    public class RestResponseCookie
    {
        /// <summary>
        /// 描述
        /// </summary>
        public string Comment { get; set; }
        /// <summary>
        /// 描述Uri地址
        /// </summary>
        public Uri CommentUri { get; set; }
        /// <summary>
        /// 如果客户端将在当前会话结束时丢弃，则为 true；否则为 false。默认值为 false。
        /// </summary>
        public bool Discard { get; set; }
        /// <summary>
        /// Cookie的作用域
        /// </summary>
        public string Domain { get; set; }
        /// <summary>
        /// 是否过期
        /// </summary>
        public bool Expired { get; set; }
        /// <summary>
        /// 过期时间
        /// </summary>
        public DateTime Expires { get; set; }
        /// <summary>
        /// 是否只允许服务器访问
        /// </summary>
        public bool HttpOnly { get; set; }
        /// <summary>
        /// 名称
        /// </summary>
        public string Name { get; set; }
        /// <summary>
        /// Cookie的有效路径Uri
        /// </summary>
        public string Path { get; set; }
        /// <summary>
        /// Cookie的有效端口号
        /// </summary>
        public string Port { get; set; }
        /// <summary>
        /// 如果客户端仅在使用安全超文本传输协议 (HTTPS) 的后继请求中返回 Cookie，则为 true；否则为 false。默认值为 false。
        /// </summary>
        public bool Secure { get; set; }
        /// <summary>
        /// Cookie返回的时间
        /// </summary>
        public DateTime TimeStamp { get; set; }
        /// <summary>
        /// Cookie值
        /// </summary>
        public string Value { get; set; }
        /// <summary>
        /// 此 Cookie 符合的 HTTP 状态维护版本
        /// </summary>
        public int Version { get; set; }
    }
}
